<?php

namespace App\Mail;

use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue;

class FindPassword extends Mailable
{
    use Queueable, SerializesModels;

    protected $password;
    protected $attach;

    /**
     * FindPassword constructor.
     * @param $password
     * @param $attach
     */
    public function __construct($password, $attach)
    {
        $this->password = $password;
        $this->attach = $attach;
    }

    /**
     * Build the message.
     *
     * @return $this
     */
    public function build()
    {
        return $this->view('emails.password')
            ->with(['password' => $this->password])
            ->attach($this->attach);
    }
}
